<template>
  <div class="app-container">
    <el-tabs type="border-card">
      <el-tab-pane
        :label="item.categoryName"
        v-for="item in typesData"
        :key="item.categoryType"
      >
        <Setting :key="item.categoryType + '_setting'" :categoryType="item.categoryType"/>
      </el-tab-pane>
    </el-tabs>
  </div>
</template>

<script>
import Setting from "./components/setting.vue";
import {
  apiServiceCategoryGetRootCategory,
} from "@/api/serviceClassify";

export default {
  components: { Setting },
  methods: {},
  data() {
    return {
      typesData: [],
  
    };
  },
  mounted() {
    console.log(1);
    this.getData();
  },
  methods: {
    getData() {
      apiServiceCategoryGetRootCategory().then((res) => {
        this.typesData = res.data;
      });
    },
  },
};
</script>

